import { createApp } from 'vue'
import App from './App.vue'
import router from './router'
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
// Import the icon components you need
import * as ElIcons from '@element-plus/icons-vue'
import Echarts from "vue-echarts"
import * as echarts from "echarts"

const app = createApp(App)

// Register all icons globally
for (const [key, component] of Object.entries(ElIcons)) {
  app.component(key, component)
}

app.use(router).use(ElementPlus).mount('#app').component("v-chart", Echarts)

app.config.globalProperties.$echarts = echarts